/**
 * futures : masterlink.futures.vo.SysTrid.java
 */
package masterlink.futures.vo;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * TODO Write the description
 *
 * @author : tonyyang
 * Create date : 2012/6/15
 * @version 1.0.0	
 */
@Entity
@Table(name="SYS_TRID")
public class SysTrid implements Serializable{

	private static final long serialVersionUID = -7153772338088972727L;
	@Id
	private String trid;
	@Column(name="name")
	private String name;
	@Column(name="cnt")
	private int cnt;
	@Column(name="category")
	private int category;
	/**
	 * @return the trid
	 */
	public String getTrid() {
		return trid;
	}
	/**
	 * @param trid the trid to set
	 */
	public void setTrid(String trid) {
		this.trid = trid;
	}
	/**
	 * @return the name
	 */
	public String getName() {
		return name;
	}
	/**
	 * @param name the name to set
	 */
	public void setName(String name) {
		this.name = name;
	}
	/**
	 * @return the cnt
	 */
	public int getCnt() {
		return cnt;
	}
	/**
	 * @param cnt the cnt to set
	 */
	public void setCnt(int cnt) {
		this.cnt = cnt;
	}
	/**
	 * @return the category
	 */
	public int getCategory() {
		return category;
	}
	/**
	 * @param category the category to set
	 */
	public void setCategory(int category) {
		this.category = category;
	}
	/* (non-Javadoc)
	 * @see java.lang.Object#toString()
	 */
	@Override
	public String toString() {
		StringBuilder builder = new StringBuilder();
		builder.append("SysTrid [trid=");
		builder.append(trid);
		builder.append(", name=");
		builder.append(name);
		builder.append(", cnt=");
		builder.append(cnt);
		builder.append(", category=");
		builder.append(category);
		builder.append("]");
		return builder.toString();
	}
	/* (non-Javadoc)
	 * @see java.lang.Object#hashCode()
	 */
	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((trid == null) ? 0 : trid.hashCode());
		return result;
	}
	/* (non-Javadoc)
	 * @see java.lang.Object#equals(java.lang.Object)
	 */
	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (!(obj instanceof SysTrid))
			return false;
		SysTrid other = (SysTrid) obj;
		if (trid == null) {
			if (other.trid != null)
				return false;
		} else if (!trid.equals(other.trid))
			return false;
		return true;
	}
}
